const TOKEN_KEY = 'hzz-news-token'
export const setToken = token => {
  localStorage.setItem(TOKEN_KEY, JSON.stringify(token))
}

export const removeToken = () => {
  localStorage.removeItem(TOKEN_KEY)
}

export const getToken = () => {
  return JSON.stringify(localStorage.getItem(TOKEN_KEY)) || {}
}
